<?php

use Phinx\Migration\AbstractMigration;

class AddSignKeywordColumnInContractTemplateTable extends AbstractMigration
{
    public function up()
    {
        $this->table("contract_template")
            ->addColumn("party_a_sign_keyword", "string", [
                'default' => '',
                'limit' => 255,
                'null' => false,
                'comment' => "合同甲方签署关键字"
            ])
            ->addColumn("party_b_sign_keyword", "string", [
                'default' => '',
                'limit' => 255,
                'null' => false,
                'comment' => "合同乙方签署关键字"
            ])
            ->save();
    }

    public function down()
    {
        $this->table("contract_template")
            ->removeColumn("party_a_sign_keyword")
            ->removeColumn("party_b_sign_keyword")
            ->save();
    }
}
